package model

import (
	"time"

	"open/internal/model/field"
)

// EventMessage 事务性消息
type EventMessage struct {
	BaseModel
	Topic       string     `gorm:"comment:消息topic"`
	MsgKey      string     `gorm:"comment:消息唯一标识"`
	Payload     field.JSON `gorm:"comment:消息内容"`
	Status      int        `gorm:"comment:消息状态， 0~初始，1~成功，2~标记成功"`
	ExecuteTime *time.Time `gorm:"comment:下一次执行时间"`
	Retry       int        `gorm:"comment:重试次数"`
}
